home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 2000 August: Tool Chest / Dev.CD Aug 00 TC Disk 2.toast / pc / sample code / processes / mp threaded sort / appleeventhandling.h < prev    next >
Encoding:
C/C++ Source or Header  |  2000-06-23  |  2.5 KB  |  71 lines

  1. /*
  2.     File:        AppleEventHandling.h
  3.  
  4.     Contains:    Minimalist support for the required and Display Manager suites
  5.                 To really support AppleScript™, we’ll do more work in here.
  6.  
  7.     Written by: Dave Falkenburg    
  8.  
  9.     Copyright:    Copyright © 1993-1999 by Apple Computer, Inc., All Rights Reserved.
  10.  
  11.                 You may incorporate this Apple sample source code into your program(s) without
  12.                 restriction. This Apple sample source code has been provided "AS IS" and the
  13.                 responsibility for its operation is yours. You are not permitted to redistribute
  14.                 this Apple sample source code as "Apple sample source code" after having made
  15.                 changes. If you're going to re-distribute the source, we require that you make
  16.                 it clear in the source that the code was descended from Apple sample source
  17.                 code, but that you've made changes.
  18.  
  19.     Change History (most recent first):
  20.                 7/27/1999    Karl Groethe    Updated for Metrowerks Codewarror Pro 2.1
  21.                 11/16/94    DRF                Add StandardAEIdleProc for people who like using AESend with
  22.                                             kAEWaitReply.
  23.                 11/12/94    DRF                AppConditionals.h -> BuildConditionals.h
  24.                   9/4/94    DRF                Added Text Services AppleEvent handlers.
  25.  
  26. */
  27.  
  28. #ifndef        _APPLEEVENTHANDLING_
  29. #define        _APPLEEVENTHANDLING_
  30.  
  31. #ifndef        __APPLEEVENTS__
  32. #include    <AppleEvents.h>
  33. #endif
  34.  
  35. #ifndef        __OCESTANDARDMAIL__
  36. #include    <OCEStandardMail.h>
  37. #endif
  38.  
  39.  
  40. void                InstallAppleEventHandlers(void);
  41. OSErr                CheckAppleEventForMissingParams(AppleEvent * theAppleEvent);
  42. extern AEIdleUPP    StandardAEIdleUPP;
  43.  
  44. //    Handlers for the Required Suite:
  45.  
  46. typedef OSErr        (*EachDocumentProcPtr)(LetterDescriptor *aFile,void * param);
  47. OSErr                ForEachDocumentInList(AEDescList documentList,EachDocumentProcPtr documentProc,void * documentParam);
  48.  
  49. pascal OSErr        HandleOpenApplication(AppleEvent * theAppleEvent,AppleEvent * reply, long refCon);
  50. pascal OSErr        HandleOpenDocuments(AppleEvent * theAppleEvent,AppleEvent * reply, long refCon);
  51. pascal OSErr        HandlePrintDocuments(AppleEvent * theAppleEvent,AppleEvent * reply, long refCon);
  52. pascal OSErr        HandleQuitApplication(AppleEvent * theAppleEvent,AppleEvent * reply, long refCon);
  53.  
  54.  
  55. //    Display Manager:
  56.  
  57. pascal OSErr    HandleSystemConfigNotice(AppleEvent *theAppleEvent,AppleEvent *reply,long refCon);
  58.  
  59.  
  60. #if    qInlineInputAware
  61.  
  62. //    Text Services Manager:
  63.  
  64. pascal OSErr    HandleTextServicesUpdateActiveInputArea(AppleEvent *theAppleEvent,AppleEvent *reply,long refCon);
  65. pascal OSErr    HandleTextServicesPos2Offset(AppleEvent *theAppleEvent,AppleEvent *reply,long refCon);
  66. pascal OSErr    HandleTextServicesOffset2Pos(AppleEvent *theAppleEvent,AppleEvent *reply,long refCon);
  67.  
  68. #endif
  69.  
  70. #endif
  71.